<template>
    <div class=‘mask’ v-if='showModal' @click='closeModal'>
        <div>
            <i @click='closeModal'>X</i>
            <h3>对不起，暂不回收此书！</h3>
        </div>
    </div>
</template>
<script>
export default {
  props: ['showModal'],
  methods: {
    closeModal() {
      this.showModal = false
    }
  }
}
</script>
<style lang="scss" scoped>
.mask {
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 10000;
  position: fixed;
  left: 0;
  top: 0;
  div {
    width: 362rpx;
    height: 180rpx;
    background: #fff;
    position: absolute;
    border-radius: 10rpx;
    color: #2b2b2b;
    font-size: 26rpx;
    top: 50%;
    left: 50%;
    line-height: 180rpx;
    text-align: center;
    transform: translate(-50%, -50%);
    i {
      position: absolute;
      right: 10rpx;
      top: 10rpx;
      line-height: 24rpx;
    }
  }
}
</style>
